
var data = "Hello World"

type
  Comparable = concept a
    (a < a) is bool

proc countData(param: string) {.thread.} =
  for i in 0 ..< param.len:   
    stdout.write($i)          
  echo()                      

var threads: array[2, Thread[string]]
var x =     threads[0]
createThread[string](x, countData, data)
for i in 0..high(threads):
  createThread[string](threads[i], countData, data)  
joinThreads(threads)          

